package com.dao.purchase;

import com.model.purchase.AgreeMmModel;
import java.sql.SQLException;
import java.util.List;
import java.util.Map;
import org.apache.ibatis.annotations.Param;

public interface AgreeMmDao {

	/**
	 * 新增
	 * 
	 * @author chenjun
	 * @date 2022/03/10
	 **/
	int insert(AgreeMmModel agreeMmModel);

	int deleteByInfId(String infId);

	List<AgreeMmModel> selectByInfId(String infId);

	int deleteByResId(String resId);

	List<AgreeMmModel> selectByResId(String resId);

	int deleteByMmId(String mmId);

	List<AgreeMmModel> selectByMmId(String mmId);

	/**
	 * 刪除
	 * 
	 * @author chenjun
	 * @date 2022/03/10
	 **/
	int delete(@Param("infId") String infId, @Param("resId") String resId, @Param("mmId") String mmId);

	/**
	 * 更新
	 * 
	 * @author chenjun
	 * @date 2022/03/10
	 **/
	int update(AgreeMmModel agreeMmModel);

	/**
	 * 查询 根据主键 id 查询
	 * 
	 * @author chenjun
	 * @date 2022/03/10
	 **/
	AgreeMmModel load(@Param("infId") String infId, @Param("resId") String resId, @Param("mmId") String mmId);

	// 列表
	List<AgreeMmModel> selectList(Map<String, Object> map);

	// 列表总数
	int selectListCount(Map<String, Object> map);
}